﻿namespace KeyWordSearch.TreeParser
{
	public abstract class RuntimeCompilingException : System.ApplicationException
	{
		protected RuntimeCompilingException(string message, string source, int startIndex, int length)
			: base(message)
		{
			this.Souce = Souce;
			this.StartIndex = startIndex;
			this.Length = length;
		}

		public int StartIndex
		{
			get;
			private set;
		}

		public int Length
		{
			get;
			private set;
		}

		public string Souce
		{
			get;
			private set;
		}
	}

	public class LexicalException:RuntimeCompilingException
	{
		public LexicalException(string message, string source, int startIndex, int length) :
			base(message, source, startIndex,length)
		{
		}
	}
}
